pid = url('?pid')
$('.evalution_result a').attr('href','evalution/resultWeapp.html?from=weapp&pid='+patientId) 
//nav---量表评估---患者行为量表
let nav_assess_behavior = [
	{
		// img: "img/evalution/sdsca.png",
		title: '自我管理行为(SDSCA)',
		link: 'sdsca',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/behavior/sdscaInfo.html?from=weapp&pid='+pid,
	},
	// {
	// 	// img: "img/evalution/c-dmses.png",
	// 	title: "自我管理效能(C-DMSES)",
	// 	link: "c-dmses",
	// 	time: "答题时间:10分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	// {
	// 	// img: "img/evalution/dcp.png",
	// 	title: "密西根糖尿病管理评定量表(DCP)",
	// 	link: "dcp",
	// 	time: "答题时间:10分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	// {
	// 	// img: "img/evalution/adknowl.png",
	// 	title: "患者知识量表(ADKnowl)",
	// 	link: "adknowl",
	// 	time: "答题时间:60分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	{
		// img: "img/evalution/mmas-8.png",
		title: 'Morisky用药依从性问卷(MMAS-8)',
		link: 'mmas-8',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/behavior/mmas8Info.html?from=weapp&pid='+pid,
	},
	{
		// img: "img/evalution/bmq.png",
		title: '服药信念量表(BMQ)',
		link: 'bmq',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/behavior/bmqInfo.html?from=weapp&pid='+pid,
	},
]

//nav---量表评估---疾病评估量表
let nav_assess_disease = [
	// {
	// 	// img: "img/evalution/complication.png",
	// 	title: "并发症评估",
	// 	link: "complication",
	// 	time: "答题时间:10分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	{
		// img: "img/evalution/diabetes.png",
		title: '糖尿病风险评估',
		link: 'diabetes',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/disease/diabetesInfo.html?from=weapp&pid='+pid,
	},
	{
		// img: "img/evalution/cardiovascular.png",
		title: '心血管十年风险评估',
		link: 'cardiovascular',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/disease/cardiovascularInfo.html?from=weapp&pid='+pid,
	},
]
//nav---量表评估---心里行为量表
let nav_assess_psychology = [
	{
		// img: "img/evalution/sas.png",
		title: '焦虑自评(SAS)',
		link: 'sas',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/psychology/sasInfo.html?from=weapp&pid='+pid,
	},
	{
		// img: "img/evalution/sds.png",
		title: '抑郁自评(SDS)',
		link: 'sds',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/psychology/sdsInfo.html?from=weapp&pid='+pid,
	},
	// {
	// 	// img: "img/evalution/16pf.png",
	// 	title: "卡特尔十六种人格因素测验(16PF) ",
	// 	link: "16pf",
	// 	time: "答题时间:60分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	{
		// img: "img/evalution/burnout.png",
		title: '马氏工作倦怠通用量表',
		link: 'burnout',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/psychology/burnoutInfo.html?from=weapp&pid='+pid,
	},
	// {
	// 	// img: "img/evalution/style.png",
	// 	title: "明尼苏达多相个性测查表",
	// 	link: "style",
	// 	time: "答题时间:3小时",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	{
		// img: "img/evalution/psqi.png",
		title: '匹兹堡睡眠质量指数(PSQI)',
		link: 'psqi',
		time: '答题时间:10分钟',
		count: '未填写',
		linkpath: 'evalution/psychology/psqiInfo.html?from=weapp&pid='+pid,
	},
	// {
	// 	// img: "img/evalution/scl-90.png",
	// 	title: "心理健康临床症状自评测验(SCL-90)",
	// 	link: "scl-90",
	// 	time: "答题时间:60分钟",
	// 	count: '未填写',
	// 	linkpath: "",
	// },
	{
		// img: "img/evalution/happiness.png",
		title: '总体幸福感测试',
		link: 'happiness',
		time: '答题时间:30分钟',
		count: '未填写',
		linkpath: 'evalution/psychology/happinessInfo.html?from=weapp&pid='+pid,
	},
]

//nav---量表评估---体能
let nav_assess_sport = [
	{
		// img: "img/evalution/sas.png",
		title: '体能活动就绪问卷',
		link: 'sport',
		time: '答题时间:5分钟',
		count: '未填写',
		linkpath: 'evalution/others/sportInfo.html?from=weapp&pid='+pid,
	}
]

//nav---量表评估---营养
let nav_assess_nur = [
	{
		// img: "img/evalution/sas.png",
		title: '营养风险筛查评估表',
		link: 'nur',
		time: '答题时间:5分钟',
		count: '未填写',
		linkpath: 'evalution/others/nurInfo.html?from=weapp&pid='+pid,
	}
]

$.each(nav_assess_behavior, function (i, v) {
	var html = [
		'<li class="nav_evalution" linkpath=' + v.linkpath + '>',
		'	<div >',
		'<span class="icon">',

		'</span>',
		// '		<img src="' + v.img + '"/>',
		'	<span class="evalution_title1">' + v.title + '</span>',
		'<div class="evalution_time">',
		'<span class="evalution_left">' + v.time + '</span>',
		'<span class="evalution_right evalution_count1' +
			i +
			'">' +
			v.count +
			'</span>',

		'</div>',
		'	</div>',
		'</li>',
	].join('')
	$(html).appendTo('.nav_list_assess_behavior')
})

$.each(nav_assess_disease, function (i, v) {
	var html = [
		'<li class="nav_evalution" linkpath=' + v.linkpath + '>',
		'	<div >',
		'<span class="icon">',

		'</span>',
		// '		<img src="' + v.img + '"/>',
		'	<span class="evalution_title1">' + v.title + '</span>',
		'<div class="evalution_time">',
		'<span class="evalution_left">' + v.time + '</span>',
		'<span class="evalution_right evalution_count2' +
			i +
			'">' +
			v.count +
			'</span>',

		'</div>',
		'	</div>',
		'</li>',
	].join('')
	$(html).appendTo('.nav_list_assess_disease')
})

$.each(nav_assess_psychology, function (i, v) {
	var html = [
		'<li class="nav_evalution" linkpath=' + v.linkpath + '>',
		'	<div >',
		'<span class="icon">',

		'</span>',
		// '		<img src="' + v.img + '"/>',
		'	<span class="evalution_title1">' + v.title + '</span>',
		'<div class="evalution_time">',
		'<span class="evalution_left">' + v.time + '</span>',
		'<span class="evalution_right evalution_count3' +
			i +
			'">' +
			v.count +
			'</span>',

		'</div>',
		'	</div>',
		'</li>',
	].join('')
	$(html).appendTo('.nav_list_assess_psychology')
})

$.each(nav_assess_sport, function (i, v) {
	var html = [
		'<li class="nav_evalution" linkpath=' + v.linkpath + '>',
		'	<div >',
		'<span class="icon">',

		'</span>',
		'	<span class="evalution_title1">' + v.title + '</span>',
		'<div class="evalution_time">',
		'<span class="evalution_left">' + v.time + '</span>',
		'<span class="evalution_right evalution_count4">' +
			v.count +
			'</span>',

		'</div>',
		'	</div>',
		'</li>',
	].join('')
	$(html).appendTo('.nav_list_assess_sport')
})

$.each(nav_assess_nur, function (i, v) {
	var html = [
		'<li class="nav_evalution" linkpath=' + v.linkpath + '>',
		'	<div >',
		'<span class="icon">',

		'</span>',
		'	<span class="evalution_title1">' + v.title + '</span>',
		'<div class="evalution_time">',
		'<span class="evalution_left">' + v.time + '</span>',
		'<span class="evalution_right evalution_count5">' +
			v.count +
			'</span>',

		'</div>',
		'	</div>',
		'</li>',
	].join('')
	$(html).appendTo('.nav_list_assess_nur')
})


$('.nav_evalution').each(function (i) {
	$('.nav_evalution')
		.eq(i)
		.click(function () {
			if ($(this).attr('linkpath')) {
				window.location.href = $(this).attr('linkpath')
			} else {
				syalert.syopen('alert3')
			}
		})
})
